# create a new koji builder on raw hw
# NOTE: should be used with --limit most of the time
# NOTE: most of these vars come from group_vars/buildhw or from hostvars

- name: make koji builder(s) on raw hw
  hosts: buildhw;buildppc;buildarm
  user: root
  gather_facts: True

  vars_files: 
   - /srv/web/infra/ansible/vars/global.yml
   - ${private}/vars.yml
   - ${vars}/${ansible_distribution}.yml

  tasks:
  - include: $tasks/yumrepos.yml
  - include: $tasks/koji/base_builder.yml

  handlers:
  - include: $handlers/restart_services.yml

  - name: restart kojid
    action: service name=kojid state=restarted
  


- name: make koji builder(s) on raw hw
  hosts: buildhw
  user: root
  gather_facts: True

  vars_files: 
   - /srv/web/infra/ansible/vars/global.yml
   - ${private}/vars.yml
   - ${vars}/${ansible_distribution}.yml

  tasks:
  - include: $tasks/koji/builder_kernel_config.yml

  handlers:
  - include: $handlers/restart_services.yml

  - name: restart kojid
    action: service name=kojid state=restarted
  

